﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Serialization;

namespace OBUCare.Core.Models
{
    /// <summary>
    ///  代码表数据的系统状态:0（正常） , -1(已删除)。代码表被删除，则对应的字段也将被删除
    /// </summary>
    public enum DictTypeStatus : int
    {
        /// <summary>
        /// 已停用
        /// </summary>
        NotUsed = -2,
        /// <summary>
        /// 已标记删除
        /// </summary>
        Deleted = -1,
        /// <summary>
        /// 正常
        /// </summary>
        Normal = 0
    }

    /// <summary>
    /// 元器件交接类型:类型 1 划拨 2 调库 3 退库 4 冲正
    /// </summary>
    public enum Parts_Transfer_Kind
    {
        /// <summary>
        /// 划拨
        /// </summary>
        Transfer = 1,
        /// <summary>
        /// 调库
        /// </summary>
        Change = 2,
        /// <summary>
        /// 退库
        /// </summary>
        Return = 3,
        /// <summary>
        /// 冲正
        /// </summary>
        Reversal
    }

    /// <summary>
    /// 维修单状态
    /// </summary>
    public enum RepairOrderStatus : int
    {
        /// <summary>
        /// 待退回维修组:1
        /// </summary>
        ReadyForReturnToRepairGroup = 1,
        /// <summary>
        /// 已退回维修组:2
        /// </summary>
        ReturnedToRepairGroup = 2,
        /// <summary>
        /// 待返回厂商:3
        /// </summary>
        ReadyForReturnToSupplier = 3,
        /// <summary>
        /// 已返回厂商:4
        /// </summary>
        ReturnedToSupplier = 4,
        /// <summary>
        /// 厂商返回报价:5
        /// </summary>
        SupplierReturnedRepariPrice = 5,

        /// <summary>
        /// 客户已确认是否维修:6
        /// </summary>
        ConfirmedWithRepairByCustomer = 6,
        ///// <summary>
        ///// 客户已确认不维修:7
        ///// </summary>
        //ConfirmedWithoutRepairByCustomer,
        /// <summary>
        /// 已通知厂商维修:8
        /// </summary>
        InformeSupplierToRepair = 8,
        /// <summary>
        /// 维修返回中心库:9
        /// </summary>
        RepairedAndReturnedToRepariGroup = 9,

        /// <summary>
        /// 维修返回营业厅,但没有被营业厅确认:10
        /// </summary>
        RepairedAndReturnedToAgent = 10,
        /// <summary>
        /// 待通知客户:11
        /// </summary>
        ReadyForInformCustomer = 11,
        /// <summary>
        /// 已通知客户领取:12
        /// </summary>
        InformedCustomer = 12,
        /// <summary>
        /// 客户未领取、维修结束:13
        /// </summary>
        ClosedWithoutCustomerPickedBack = 13,
        /// <summary>
        /// 客户已领取、维修结束:14
        /// </summary>
        ClosedWithCustomerPickedBack = 14,
        /// <summary>
        /// 未联系上客户：15
        /// </summary>
        ConnectionWithoutCustomers = 15,
        /// <summary>
        /// 未联系到客户领签
        /// </summary>
        InformedWithoutCustomer = 16,
        /// <summary>
        /// 一口价维修
        /// </summary>
        OneRepair = 17
    }

    /// <summary>
    /// 交接单状态
    /// </summary>
    public enum TransferStatus : int
    {
        /// 正常
        /// </summary>
        Normal = 0,
        /// <summary>
        /// 已经确认
        /// </summary>
        Confirmed = 1,

        /// <summary>
        /// 作废
        /// </summary>
        Obsolete = -1
    }

    /// <summary>
    /// 交接单类型
    /// </summary>
    public enum TransferType
    {
        /// <summary>
        /// 营业厅->维修组
        /// </summary>
        AgentToRepairCenter = 1,
        /// <summary>
        /// 维修组->厂商
        /// </summary>
        RepairCenterToSupplier,
        /// <summary>
        /// 厂商->维修组
        /// </summary>
        SupplierToRepairCenter,
        /// <summary>
        /// 维修组->营业厅
        /// </summary>
        RepairCenterToAgent
    }

    /// <summary>
    /// 交易类型
    /// </summary>
    public enum TransactionType
    {
        /// <summary>
        /// 标签维修
        /// </summary>
        RepairObu = 3001,
        /// <summary>
        /// 备胶销售
        /// </summary>
        IssueSpareTape = 3002,
        /// <summary>
        /// 底座销售
        /// </summary>
        IssueBase = 3003,
        /// <summary>
        /// 收取押金
        /// </summary>
        CollectsDeposit = 3004,
        /// <summary>
        /// 维修服务费
        /// </summary>
        RepairServiceFee = 3005,
        /// <summary>
        /// 退后押金
        /// </summary>
        ReturnDeposit = 3006,
        /// <summary>
        /// 一口价维修
        /// </summary>
        OneRepair = 3007

    }

    /// <summary>
    /// 标签操作类型
    /// </summary>
    public enum OpKindObuTradein
    {
        标签以旧换新_标签正常 = 175,
        标签以旧换新_标签损坏 = 178,
        标签以旧换新发行 = 187,
        标签以旧换翻新发行 = 188,
        标签以旧换翻新更换 = 189,
        标签以旧换翻新更换_标签损坏 = 190,
        标签密钥升级 = 196
    }

    /// <summary>
    /// 费用调整类型
    /// </summary>
    public enum AdjustType : int
    {
        /// <summary>
        /// 维修费调整
        /// </summary>
        AdjustRepairFee = 1,
        /// <summary>
        /// 服务费调整
        /// </summary>
        AdjustServiceFee = 2,
        /// <summary>
        /// 服务费生成
        /// </summary>
        GenerateServiceFee = 3
    }

    /// <summary>
    /// 处置方式
    /// </summary>
    public enum DisposeType : int
    {
        /// <summary>
        /// 维修
        /// </summary>
        Repair = 1,
        /// <summary>
        /// 置换
        /// </summary>
        Replace
    }

    /// <summary>
    /// 确认是否维修
    /// </summary>
    public enum ConfirmRepairedStatus : int
    {
        /// <summary>
        /// 待确认
        /// </summary>
        WaitingForConfirm = 0,
        /// <summary>
        /// 维修
        /// </summary>
        Repair,
        /// <summary>
        /// 不维修
        /// </summary>
        NotRepair
    }

    public enum ServiceFeeCheck : int
    {
        /// <summary>
        /// 服务费单价(逾期每日所需服务费)
        /// </summary>
        ServiceFeePrice = 5,
        /// <summary>
        /// 服务费开始计算日
        /// </summary>
        ServiceFeeDay = 20,
        /// <summary>
        /// 不可领取标签(逾期多少天不允许领取标签)
        /// </summary>
        CanNotReceive = 120
    }

    /// <summary>
    /// 具有文本和值类
    /// </summary>
    public class ValueText
    {
        public string Value { get; set; }

        public string Text { get; set; }
    }
}
